package edu.rmit.util;

import java.awt.Component;

import javax.swing.JOptionPane;

/**
 * A utility class to implement the show the dialog window.
 * @author Joey George
 *
 */
public class PromotDialog {
	
	public static void errorMessageBox(Component parent, String title,
			String reason) {
		JOptionPane.showMessageDialog(parent, reason, title,
				JOptionPane.ERROR_MESSAGE);
	}
	
	public static void successMessageBox(Component parent, String title,
			String reason) {
		JOptionPane.showMessageDialog(parent, reason, title,
				JOptionPane.CLOSED_OPTION);
	}
	
	public static void infoMessageBox(Component parent, String title,String info){
		JOptionPane.showMessageDialog(parent, info, title,
				JOptionPane.INFORMATION_MESSAGE);
	}
}
